package org.swimv2.model;

import java.io.Serializable;
import javax.persistence.*;

/**
 * The primary key class for the feedback database table.
 * 
 */
@Embeddable
public class FeedbackPK implements Serializable {
	//default serial version id, required for serializable classes.
	private static final long serialVersionUID = 1L;

	private String IDLavoro;

	private String userIDdestinatario;

	public FeedbackPK() {
	}
	public String getIDLavoro() {
		return this.IDLavoro;
	}
	public void setIDLavoro(String IDLavoro) {
		this.IDLavoro = IDLavoro;
	}
	public String getUserIDdestinatario() {
		return this.userIDdestinatario;
	}
	public void setUserIDdestinatario(String userIDdestinatario) {
		this.userIDdestinatario = userIDdestinatario;
	}

	public boolean equals(Object other) {
		if (this == other) {
			return true;
		}
		if (!(other instanceof FeedbackPK)) {
			return false;
		}
		FeedbackPK castOther = (FeedbackPK)other;
		return 
			this.IDLavoro.equals(castOther.IDLavoro)
			&& this.userIDdestinatario.equals(castOther.userIDdestinatario);
	}

	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.IDLavoro.hashCode();
		hash = hash * prime + this.userIDdestinatario.hashCode();
		
		return hash;
	}
}